package com.mao.wx.demo.config;

import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.annotation.EnableAspectJAutoProxy;
import org.springframework.context.annotation.PropertySource;
import org.springframework.transaction.annotation.EnableTransactionManagement;

import com.mao.wx.demo.xml.WxXppStreamDriver;
import com.thoughtworks.xstream.XStream;

@Configuration
@EnableTransactionManagement
@EnableAspectJAutoProxy
@ComponentScan(basePackages = { "com.mao.wx.demo.model", "com.mao.wx.demo.util" })
@PropertySource("classpath:app.properties")
@PropertySource("classpath:wx.properties")
public class RootConfig {

	
	@Bean
	@Qualifier("wxXStrem")
	public XStream getXSteam(){
		XStream xStream=new XStream(new WxXppStreamDriver());
		return xStream;
	}
}
